import request from '@/api/http'
import request_file from '@/api/http_file'

export const addMstInfo = (addForm) => {
  return request.post('/mst/mstInfo/addMstInfo', addForm)
}
export const getMstInfo = (pageInfo) => {
  return request.post('/mst/mstInfo/getMstInfo', pageInfo)
}
export const delMstInfo = (ids) => {
  return request.delete('/mst/mstInfo/delMstInfo?ids=' + ids)
}
export const getMstInfoById = (id) => {
  return request.get('/mst/mstInfo/getMstInfoById', {
    params: {
      id: id
    }
  })
}
export const editMstInfo = (editForm) => {
  return request.post('/mst/mstInfo/editMstInfo', editForm)
}

export const down = () => {
  // return request_file.post('/mst/mstInfo/down')
  return request_file({
    url: '/mst/mstInfoDownLoad/down',
    method: 'get',
    // headers: { 'Content-Type': 'image/png; charset=UTF-8' },
    responseType: 'blob'// response类型

  })
}
